<?php
/**
 * 绩效管理验证器
 */

namespace app\common\validate;

class PerformanceValidate extends Validate
{
    protected $rule = [
        'staff_id|员工id' => 'require',
        'department_id|部门id' => 'require',
        'score|绩效得分' => 'require',
        'bonus|奖金' => 'require',
        'performance_time|绩效日期' => 'require',

    ];

    protected $message = [
        'staff_id.require' => '员工id不能为空',
        'department_id.require' => '部门id不能为空',
        'score.require' => '绩效得分不能为空',
        'bonus.require' => '奖金不能为空',
        'performance_time.require' => '绩效日期不能为空',

    ];

    protected $scene = [
        'add' => ['staff_id', 'department_id', 'score', 'performance_time',],
        'edit' => ['score', 'performance_time',],

    ];


}
